import { createStore } from 'vuex'

const state = {
    userName:'',
    msgState:{
        name:'',
        title:'',
        content:''
    }
}

const mutations = {
    loginMut(state, userName) {
        state.userName = userName
    },
    saveMsgMut(state,msgState){
        state.msgState = msgState
    }
}

export default createStore({
    state,
    mutations
})